<template>
	<view :style="themeColor">
		<view class="page">
			<view class="flex align-stretch benben-position-layout flex recommendCommodityList_flex_0"
				:style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx', }">
				<view class='flex align-center justify-between recommendCommodityList_fd0_0'>
					<view class='flex align-center' @tap.stop="handleJumpDiy" data-type="back" data-url="1">
						<text class='fu-iconfont2  recommendCommodityList_fd0_0_c0_c0'>&#xE794;</text>
					</view>
					<view style="font-size: 36rpx;font-weight: 500;">全部评价</view>
					<view class="recommendCommodityList_fd0_0_c0_c0"></view>
				</view>
			</view>
			<view :style="{height: (88+StatusBarRpx)+'rpx'}"></view>
			<view class="loading_css" v-if="isShow">
				<u-loading size="36" color="#F35D2A"></u-loading>
				<view>加载中</view>
			</view>
			<block v-else>
				<view class="evaluate_content">
					<view class="evaluate_item" v-for="(v, k) in list" :key="k">
						<view class="evaluate_name">
							<view class="evaluate_img">
								<image :src='v.head_img' mode="aspectFill"></image>
							</view>
							<view class="evaluate_user">
								<view class="evaluate_user_name">
									<view class="evaluate_user_name_1">{{v.user_nickname}}</view>
									<view class="">
										<u-rate :disabled="true" :count="5" v-model="v.course_spec_stars"
											active-color="#FC5830" inactive-color="#C1C1C1" gutter="0"
											size="20"></u-rate>
									</view>
								</view>
								<view class="evaluate_user_date">
									{{v.create_time}}
								</view>
							</view>
						</view>
						<view class="evaluate_text">{{v.content}}</view>
						<view class="evaluate_imgs" v-if="v.images.length > 0">
							<image v-for="(v1, k1) in v.images" :key="k1" class="evaluate_imgs_1" :src='v1'
								mode="aspectFill" @tap.stop="previewImage(k1, v.images)"></image>
						</view>
					</view>
				</view>
				<view class="loadmore" v-if="last_page > 1">
					<u-loadmore font-size="24" :status="status" :icon-type="iconType" :load-text="loadText" />
				</view>
				
			</block>

			<view class="noData" v-if="list.length == 0 && !isShow">
				<image :src='STATIC_URL+"no.png"'></image>
			</view>
		</view>
	</view>
</template>
<script>
	import {
		validate
	} from '@/common/utils/validate.js'
	import reservation from "@/components/reservation/reservation.vue"
	export default {
		components: {
			reservation
		},

		data() {
			return {
				"tabsInfofd1_0_c0": {
					lineleft: '',
					lineWidth: '',
					moveX: 0,
					scrollX: 0,
					PageScrollX: 0
				},
				"minixPagingListsApi": "",
				"pageingListApiMethod": "",
				"allowOnloadGetList": false,
				"screen_id": "1",
				"screenshow": false,
				"show_id": "1",
				"dataList": [],
				"userList": [],
				"is_recommend": "",
				"grass_type": "",
				"tabs": "1",
				"keyword": "",
				"placeholder": "请输入您想要的内容",
				"cid": "",
				"swiperIndex": 1,
				"value": 4,
				"list": [],
				"page": 1,
				"is_pull": true,
				"last_page": 1,
				"status": 'loadmore',
				"iconType": 'flower',
				"loadText": {
					loadmore: '轻轻上拉',
					loading: '努力加载中',
					nomore: '我也是有底线的'
				},
				"isShow": true,
				"aid": "",
			};
		},
		computed: {
			themeColor() {
				return this.$store.getters.themeColor
			},

		},
		watch: {},
		onLoad(options) {
			let {aid} = options;
			if (aid !== undefined) this.aid = aid;
			this.getList();
		},
		onUnload() {

		},
		onReady() {

		},
		onShow() {

		},
		onHide() {

		},
		onResize() {

		},
		// 下拉刷新
		onPullDownRefresh() {
			this.page = 1;
			this.is_pull = true;
			this.isShow = true;
			this.getList();
		},
		// 上拉加载
		onReachBottom() {
			if (this.page >= this.last_page) return;
			this.status = 'loading';
			this.page++;
			setTimeout(() => {

				if (this.page >= this.last_page) this.status = 'nomore';
				else this.status = 'loading';
				this.is_pull = false;
				this.getList();
			}, 500)
		},
		onPageScroll(e) {

		},
		methods: {
			getList() {
				this.$api.post(global.API_VERSION + '65b74c638a2e1', {
					page: this.page,
					course_id: this.aid
				}).then(res => {
					uni.stopPullDownRefresh();
					this.isShow = false;
					if (res.data.code == 1) {
						this.last_page = res.data.data.last_page;
						if (this.is_pull) {
							this.list = res.data.data.data;
						} else {
							this.list = this.list.concat(res.data.data.data);
						}
					} else {
						this.$message.info(res.data.msg);
					}
				})
			},
			previewImage(index, url) {
				uni.previewImage({
					current: index,
					urls: url,
				})
			},
		}
	};
</script>
<style lang="scss" scoped>
	.course_title {
		padding: 32rpx;
		background: #fff;
		.course_title_1 {
			font-size: 32rpx;
			font-weight: 500;
			line-height: 46rpx;
		}
		.course_label {
			margin-top: 16rpx;
			display: flex;
			.course_label_item {
				color: #FD9E30;
				font-size: 20rpx;
				background: rgba(255,255,255,0.2);
				padding: 2rpx 16rpx;
				opacity: 1;
				border: 1px solid #FD9E30;
				border-radius: 35rpx;
				margin-right: 16rpx;
			}
		}
	}
	.evaluate_title {
		background: #fff;
		margin-top: 20rpx;
		display: flex;
		justify-content: space-between;
		padding: 32rpx 32rpx 24rpx;
		border-bottom: 1px solid #eee;
		.evaluate_title_left {
			display: flex;
			align-items: center;
			.evaluate_title_left_1 {
				width: 7rpx;
				height: 30rpx;
				border-radius: 4rpx;
				background: #F35D2A;
				margin-right: 16rpx;
			}
			.evaluate_title_left_2 {
				font-size: 32rpx;
				font-weight: 500;
			}
		}
		.evaluate_title_right {
			text {
				font-size: 24rpx;
				color: #999;
				margin-right: 12rpx;
			}
		}
	}
	.evaluate_content {
		background: #FFFFFF;
		padding: 0rpx 32rpx 32rpx;
		.evaluate_item {
			padding: 32rpx 0;
			border-bottom: 1px solid #eee;
			.evaluate_name {
				display: flex;
				.evaluate_img {
					width: 72rpx;
					height: 72rpx;
					image {
						width: 100%;
						height: 100%;
						border-radius: 50%;
					}
				}
				.evaluate_user {
					margin-left: 24rpx;
					width: calc(100% - 96rpx);
					.evaluate_user_name {
						display: flex;
						justify-content: space-between;
						align-items: center;
						.evaluate_user_name_1 {
							font-size: 28rpx;
						}
					}
					.evaluate_user_date {
						font-size: 20rpx;
						color: #666;
						margin-top: 4rpx;
					}
				}
			}
			.evaluate_text {
				font-size: 28rpx;
				margin-top: 24rpx;
			}
			.evaluate_imgs {
				margin-top: 24rpx;
				overflow: hidden;
				.evaluate_imgs_1 {
					width: 226rpx;
					height: 226rpx;
					border-radius: 8rpx;
					margin: 0 4rpx 4rpx 0;
				}
				.evaluate_imgs_1:nth-child(3n+3) {
					margin-right: 0;
				}
			}
		}
	}
	.introduction_content {
		background: #fff;
		padding: 0rpx 32rpx 24rpx;
	}
	.yuyue_btn {
		width: 100%;
		height: 88rpx;
		background: #F35D2A;
		position: fixed;
		left: 0;
		bottom: 0;
		line-height: 88rpx;
		text-align: center;
		font-size: 28rpx;
		color: #fff;
	}
	.index_fd1_0 {
		width: 750rpx;
		height: 750rpx;
		position: relative;
		.play_btn {
			width: 64rpx;
			height: 64rpx;
			position: absolute;
			left: 50%;
			top: 50%;
			transform: translate(-50%,-50%);
		}
	}
	.swiper_num {
		width: 70rpx;
		height: 41rpx;
		background: rgba(0, 0, 0, 0.16);
		border-radius: 21rpx;
		position: absolute;
		right: 24rpx;
		bottom: 26rpx;
		z-index: 10;
		display: flex;
		align-items: center;
		justify-content: center;
		color: #fff;
		.swiper_num_1 {
			font-size: 32rpx;
		}
		.swiper_num_2 {
			font-size: 24rpx;
		}
	}
	.searchye_fd0_0_c1_c1 {
		margin: 0rpx 0rpx 0rpx 16rpx;
		font-size: 24rpx;
		font-weight: 400;
		color: #333;
		flex: 1;
		height: 100%;
		padding: 0 48rpx 0 0;
	}
	
	.searchye_fd0_0_c1_c0 {
		width: 32rpx;
		height: 32rpx;
		border-radius: 0rpx 0rpx 0rpx 0rpx;
	}
	
	.searchye_fd0_0_c1 {
		background: #F9F9F9;
		background-size: 100% auto !important;
		border-radius: 36rpx 36rpx 36rpx 36rpx;
		width: 686rpx;
		height: 64rpx;
		margin: 0 32rpx;
		padding: 0 24rpx;
		position: relative;
	}
	.close_btn {
		width: 40rpx;
		height: 40rpx;
		position: absolute;
		top: 50%;
		transform: translateY(-50%);
		right: 16rpx;
	}
	.page {
		width: 100vw;
		overflow-x: hidden;
		min-height: calc(100vh - var(--window-bottom));
		background-size: 100% auto;
		background-color: #fff;
	}

	.recommendCommodityList_flex_0 {
		width: 750rpx;
		overflow: hidden;
		z-index: 10;
		top: 0rpx;
		background-size: 100% auto;
		background: transparent;
	}

	.recommendCommodityList_fd0_0_c1_c1 {
		font-size: 28rpx;
		font-weight: 400;
		color: var(--benbenFontColor0);
		margin: 0rpx 0rpx 0rpx 16rpx;
		width: 336rpx;
	}

	.recommendCommodityList_fd0_0_c1_c0 {
		width: 32rpx;
		height: 32rpx;
		border-radius: 0rpx 0rpx 0rpx 0rpx;
	}

	.recommendCommodityList_fd0_0_c1 {
		background: #F9F9F9;
		height: 64rpx;
		width: 436rpx;
		border-radius: 34rpx 34rpx 34rpx 34rpx;
		padding: 0rpx 24rpx 0rpx 24rpx;
		margin: 0rpx 0rpx 0rpx 32rpx;
	}

	.recommendCommodityList_fd0_0_c0_c0 {
		font-size: 36rpx;
		font-weight: 500;
		color: #333;
		width: 50rpx;
	}

	.recommendCommodityList_fd0_0 {
		padding: 0rpx 32rpx 0rpx 32rpx;
		line-height: 88rpx;
		width: 100%;
	}

	.recommendCommodityList_flex_1 {
		background: #FFFFFF;
	}

	.recommendCommodityList_titlefd1_0_c0_c4 {
		margin: 0rpx 68rpx 0rpx 68rpx;
	}
	.recommendCommodityList_titlefd1_0_c0_c5 {
		margin: 0rpx 68rpx 0rpx 68rpx;
	}

	.recommendCommodityList_titleItemfd1_0_c0_c3_c0 {
		// font-size: 28rpx;
		font-weight: 400;
	}

	.recommendCommodityList_titlefd1_0_c0_c3 {
		margin: 0rpx 64rpx 0rpx 64rpx;
		// font-size: 32rpx;
		font-weight: 500;
	}

	.recommendCommodityList_linefd1_0_c0 {
		background: #F35D2A;
		width: 40rpx;
		height: 5rpx;
		top: 84rpx;
		background-size: 100% auto !important;
		border-radius: 3rpx 3rpx 0rpx 0rpx;
	}

	.checkTitlefd1_0_c0 {
		font-weight: 500 !important;
		font-size: 32rpx !important;
		color: #333 !important;
	}

	::v-deep .recommendCommodityList_benbenTabsfd1_0_c0 {
		background: #fff;
		// width: 750rpx;
		height: 90rpx;
		white-space: nowrap;
		text-align: center;
	}

	.recommendCommodityList_fd1_0 {
		// padding: 0rpx 32rpx 0rpx 32rpx;
		justify-content: center;
	}

	.recommendCommodityList_flex_2 {
		background-size: 100% auto;
		padding: 0rpx 24rpx 0rpx 24rpx;
	}

	.recommendCommodityList_fd2_0 {
		background: var(--benbenbgColor1);
	}

	.recommendCommodityList_flex_3 {
		background-size: 100% auto;
		padding: 0rpx 24rpx 0rpx 24rpx;
	}

	.recommendCommodityList_fd3_0_c0_c2_c0 {
		width: 44rpx;
		height: 44rpx;
		border-radius: 0rpx 0rpx 0rpx 0rpx;
	}

	.recommendCommodityList_fd3_0_c0_c2 {
		position: absolute;
		right: 20rpx;
		top: 20rpx;
	}

	.recommendCommodityList_fd3_0_c0_c1_c1_c3 {
		color: #666666;
		font-size: 24rpx;
		font-weight: 400;
		max-width: 45rpx;
		-webkit-line-clamp: 1;
		overflow: hidden;
		text-overflow: ellipsis;
		display: -webkit-box;
		-webkit-box-orient: vertical;
	}

	.recommendCommodityList_fd3_0_c0_c1_c1_c2 {
		width: 32rpx;
		height: 32rpx;
		border-radius: 0rpx 0rpx 0rpx 0rpx;
		margin: 0rpx 13rpx 0rpx auto;
	}

	.recommendCommodityList_fd3_0_c0_c1_c1_c1 {
		color: #666666;
		font-size: 24rpx;
		font-weight: 400;
		margin: 0rpx 0rpx 0rpx 12rpx;
	}

	.recommendCommodityList_fd3_0_c0_c1_c1_c0 {
		width: 40rpx;
		height: 40rpx;
		border-radius: 20rpx;
	}

	.recommendCommodityList_fd3_0_c0_c1_c0 {
		color: #333333;
		font-size: 28rpx;
		font-weight: 500;
		padding: 19rpx 0rpx 24rpx 0rpx;
	}

	.recommendCommodityList_fd3_0_c0_c1 {
		padding: 0rpx 25rpx 0rpx 20rpx;
	}

	.recommendCommodityList_fd3_0_c0_c0 {
		width: 335rpx;
		height: 450rpx;
		border-radius: 0rpx 0rpx 0rpx 0rpx;
	}

	.recommendCommodityList_fd3_0_c0 {
		background: rgba(247, 246, 244, 1);
		padding: 0rpx 0rpx 24rpx 0rpx;
		background-size: 100% auto;
		position: relative;
	}

	.recommendCommodityList_flex_4 {
		background: var(--benbenbgColor1);
		padding: 0rpx 30rpx 0rpx 30rpx;
		background-size: 100% auto !important;
	}

	.recommendCommodityList_fd4_0_c2_1 {
		border: 1px solid #AD3823;
		background: rgba(173, 56, 35, 1);
		border-radius: 32rpx 32rpx 32rpx 32rpx;
		width: 172rpx;
		line-height: 64rpx;
		font-size: 32rpx;
		color: var(--benbenFontColor3);
		height: 64rpx;
	}

	.recommendCommodityList_fd4_0_c2 {
		border: 1px solid #AD3823;
		background: var(--benbenbgColor1);
		border-radius: 32rpx 32rpx 32rpx 32rpx;
		width: 172rpx;
		line-height: 64rpx;
		font-size: 32rpx;
		color: rgba(173, 56, 35, 1);
		height: 64rpx;
	}

	.recommendCommodityList_fd4_0_c1_c1_c1 {
		background: var(--benbenbgColor6);
		width: 1rpx;
		height: 30rpx;
		margin: 0rpx 10rpx 0rpx 10rpx;
		transform: scaleX(0.5);
	}

	.recommendCommodityList_fd4_0_c1_c1_c0_c1 {
		margin: 0rpx 0rpx 0rpx 10rpx;
	}

	.recommendCommodityList_fd4_0_c1_c1 {
		color: #999999;
		font-size: 24rpx;
		line-height: 33rpx;
		font-weight: 400;
	}

	.recommendCommodityList_fd4_0_c1_c0 {
		color: #000000;
		font-size: 32rpx;
		font-weight: 500;
		line-height: 40rpx;
		margin: 0rpx 0rpx 16rpx 0rpx;
	}

	.recommendCommodityList_fd4_0_c0 {
		width: 108rpx;
		height: 108rpx;
		border-radius: 54rpx;
		margin: 0rpx 23rpx 0rpx 0rpx;
	}

	.recommendCommodityList_fd4_0 {
		border-bottom: 1px solid #eee;
		padding: 32rpx 0rpx 32rpx 0rpx;
	}


	.littleTheatre_fd2_0_c1_c2_c0_c0 {
		color: #AD3823;
		font-size: 28rpx;
		font-weight: 400;
	}

	.littleTheatre_fd2_0_c1_c2_c0 {
		background: #FFFFFF;
		width: 144rpx;
		height: 52rpx;
		// transform: translateY(-12rpx);
		position: absolute;
		bottom: 0;
		right: 0;
		border-radius: 24rpx 16rpx 0 0;
	}

	.littleTheatre_fd2_0_c1_c1_c1 {
		color: #333333;
		font-size: 34rpx;
		font-weight: 400;
		margin: 15rpx 0rpx 4rpx 0rpx;
	}

	.littleTheatre_fd2_0_c1_c1_c0 {
		color: #333333;
		font-size: 48rpx;
		font-weight: 400;
	}

	.littleTheatre_fd2_0_c1_c1 {
		margin: 56rpx 0rpx 0rpx 0rpx;
	}

	.littleTheatre_fd2_0_c1_c0 {
		width: 56rpx;
		height: 56rpx;
		border-radius: 0rpx 0rpx 0rpx 0rpx;
		position: absolute;
		left: 24rpx;
		top: 24rpx;
	}

	.littleTheatre_fd2_0_c1 {
		// background: url(https://www.guochaoxiaoju.com/uploads/mini/514.png) no-repeat;
		background-size: 100% 220rpx;
		background-repeat: no-repeat;
		position: relative;
		margin: 0rpx 0rpx 24rpx 0rpx;
		height: 220rpx;
	}





	.otherFollow_fd1_1_c2_2 {
		border: 1px solid #62889B;
		background: #F8F8F8;
		border-radius: 32rpx 32rpx 32rpx 32rpx;
		width: 172rpx;
		line-height: 64rpx;
		font-size: 32rpx;
		color: rgba(98, 136, 155, 1);
		height: 64rpx;
	}

	.otherFollow_fd1_1_c2_1 {
		border: 1px solid #AD3823;
		background: var(--benbenbgColor2);
		border-radius: 32rpx 32rpx 32rpx 32rpx;
		width: 172rpx;
		line-height: 64rpx;
		font-size: 32rpx;
		color: var(--benbenFontColor3);
		height: 64rpx;
	}

	.otherFollow_fd1_1_c2 {
		border: 1px solid #AD3823;
		background: #F8F8F8;
		border-radius: 32rpx 32rpx 32rpx 32rpx;
		width: 172rpx;
		line-height: 64rpx;
		font-size: 32rpx;
		color: var(--benbenFontColor4);
		height: 64rpx;
	}

	.otherFollow_fd1_1_c1_c1_c1 {
		background: var(--benbenbgColor6);
		width: 1rpx;
		height: 30rpx;
		margin: 0rpx 10rpx 0rpx 10rpx;
		transform: scaleX(0.5);
	}

	.otherFollow_fd1_1_c1_c1_c0_c1 {
		margin: 0rpx 0rpx 0rpx 10rpx;
	}

	.otherFollow_fd1_1_c1_c1 {
		color: #999999;
		font-size: 24rpx;
		line-height: 33rpx;
		font-weight: 400;
	}

	.otherFollow_fd1_1_c1_c0 {
		color: #000000;
		font-size: 32rpx;
		font-weight: 500;
		line-height: 40rpx;
		margin: 0rpx 0rpx 16rpx 0rpx;
	}

	.otherFollow_fd1_1_c0 {
		width: 108rpx;
		height: 108rpx;
		border-radius: 54rpx;
		margin: 0rpx 23rpx 0rpx 0rpx;
	}

	.otherFollow_fd1_1 {
		border-bottom: 1px solid #eee;
		padding: 32rpx 0rpx 32rpx 0rpx;
	}
</style>